import {service} from "@/config/request.js";
 
 // 获取客户地址列表
export function getAddress(query) {
	return service({
		path: '/pigx-mall/mallOrderReceiveAddress/page',
		method: 'get', 
		params:query
	});
}  

// 新增地址列表

export function addressSave(query) {
	return service({
		path: '/pigx-mall/mallOrderReceiveAddress/save',
		method: 'post', 
		params:query
	});
}  


// 删除地址列表

export function addressDel(query) {
	return service({
		path: `/pigx-mall/mallOrderReceiveAddress/removeById?ids=${query.ids}`,
		method: 'DELETE',  
	});
}  

// 通过id查询
export function getAddressId(query) {
	return service({
		path: `/pigx-mall//mallOrderReceiveAddress/getById/${query.id}`,
		method: 'get',  
	});
}

// 编辑地址列表

export function addressEdit(query) {
	return service({
		path: '/pigx-mall//mallOrderReceiveAddress/updateById',
		method: 'PUT', 
		params:query
	});
}  


// 获取默认地址
export function jcCustomContactsPage(query) {
	console.log(query)
	return service({
		path: `/customer/jcCustomContacts/page?customId=${query.customId}`,
		method: 'get',  
	});
}  
